Title Banner

Previous Book Contents Book Index Next

Inside Macintosh: QuickTime Components /
Chapter 10 - Derived Media Handler Components / Derived Media Handler Components Reference
Functions / Graphics Data Management


MediaSetDimensions

The MediaSetDimensions function allows the Movie Toolbox to inform your media handler when its media's spatial dimensions change.

pascal ComponentResult MediaSetDimensions (ComponentInstance ci,
                                           Fixed width, 
                                           Fixed height);
ci
Identifies the Movie Toolbox's connection to your derived media handler.
width
Indicates the width, in pixels, of the track rectangle. This field, along with the height field, specifies a rectangle that surrounds the image that is displayed when the current media is played. This value corresponds to the x coordinate of the lower-right corner of the rectangle and is expressed as a fixed-point number.
height
Indicates the height, in pixels, of the track rectangle. This value corresponds to the y coordinate of the lower-right corner of the rectangle and is expressed as a fixed-point number.
DESCRIPTION
The Movie Toolbox calls your derived media handler's MediaSetDimensions function whenever the spatial dimensions of your media's track change. The toolbox provides you with the dimensions of the rectangle that encloses your media's graphical image. Changes to this rectangle may affect the way in which you display your media's data.

You obtain the initial dimension information from the width and height fields of the movie parameter structure that the Movie Toolbox provides to your MediaInitialize function (described on page 10-17).

Your derived media handler should support this function if you draw during playback.

The Movie Toolbox calls this function only if you have set the handlerHasSpatial flag to 1 in the flags parameter of the MediaSetHandlerCapabilities function (described on page 10-36).

RESULT CODES
Any Component Manager result code

SEE ALSO
The Movie Toolbox uses the MediaSetMatrix function (described in the next section) to tell your media handler about changes to either the movie matrix or the track matrix. In addition, your media handler's MediaSetClip function allows you to learn about changes to your media's clipping region. This function is discussed on page 10-32.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996




Navigation graphic, see text links

Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help